<script type="text/javascript" src="<?php echo base_url();?>js/jquery-1.9.0.js"></script>
	<script type="text/javascript" src="<?php echo base_url();?>js/jquery.validate.js"></script>
	<script type="text/javascript" src="<?php echo base_url();?>js/localization/messages_vi.js"></script>	
    <script type="text/javascript" src="<?php echo base_url();?>js/jquery-latest.js"></script>
    <script>
    $(document).ready(function() {
        $("#txtemail").blur(function() { 
            if($("#txtemail").val() != ''){
                $("#result_txtemail").html('checking...');
                }
                    var form_data = {admin_email_signin: $("#txtemail").val()};
                    $.ajax({
                        type: "POST",
                        url: "<?php echo base_url();?>index.php/login/checkvalue_email_signin",
                        data:form_data,
                        success: function(result) { 
                    $("#result_txtemail").html(result); 
                }
            });
        });
    });    
    </script>
<div id="update_ttcn">
	<h3>Cập nhật thông tin cá nhân</h3>
    <div id="noidung">
    	<?php
                        $attributes = array('id'=>'frm_capnhatttkhachhang', 'name'=>'frm_capnhatttkhachhang');			
                        echo form_open_multipart(base_url().'index.php/thongtinkh/update_check',$attributes);
                    ?>   
    	<div class ="block_cnttcn">
            <label>Họ tên:</label>
            <input class="input_cnttkh" type="text" id="txthoten" name="txthoten"  value="<?php echo $item->ho_ten;?>"/>
        </div>
         <?php echo form_error('txthoten', '<div class="error_validate_signin">', '</div>'); ?> 
        <div class ="block_cnttcn">
            <label>Ngày sinh:</label>
           
            <input  type="date" name="txtngaysinh" id="txtngaysinh"  value="<?php echo $item->ngay_sinh; ?>">
        </div>
         <?php echo form_error('txtngaysinh', '<div class="error_validate_signin">', '</div>'); ?> 
        <div class ="block_cnttcn">
            <label>Giới tính:</label>
            <span class="input_cnttkh">
                            	<input type="radio" name="rdGioiTinh" id="radio" value="<?php echo set_radio('rdGioiTinh','1') ?>"  checked="checked"/>Nam &nbsp;&nbsp;&nbsp;
								<input type="radio" name="rdGioiTinh" id="radio2" value="<?php echo set_radio('rdGioiTinh','0') ?>" />Nữ 
							</span> 
        </div>
        <div class ="block_cnttcn">
            <label>Địa chỉ:</label>
            <textarea class="input_cnttkh" id="txtdiachi" name="txtdiachi" rows="5" cols=50" >
            <?php echo $item->dia_chi;?>
            </textarea>
           
        </div>
        <?php echo form_error('txtdiachi', '<div class="error_validate_signin">', '</div>'); ?> 
        <div class ="block_cnttcn">
            <label>Email:</label>
            <input class="input_cnttkh" type="text" id="txtemail" name="txtemail"  value="<?php echo $item->email;?>"/>
        </div>
        <?php echo form_error('txtemail', '<div class="error_validate_signin">', '</div>'); ?> 
        <div class ="block_cnttcn">
            <label>Số điện thoại:</label>
            <input class="input_cnttkh" type="text" id="txtsodienthoai" name="txtsodienthoai"  value="<?php echo $item->sdt;?>"/>
        </div>
        <?php echo form_error('txtsodienthoai', '<div class="error_validate_signin">', '</div>'); ?> 
        <div class ="block_cnttcn">
            <label>Số CMND:</label>
            <input class="input_cnttkh" type="text" id="txtsocmnd" name="txtsocmnd"  value="<?php echo $item->cmnd;?>"/>
        </div>
        <?php echo form_error('txtsocmnd', '<div class="error_validate_signin">', '</div>'); ?> 
        <input type="submit" value="Lưu thay đổi">
    </div>
</div>